package com.ssy.lingxi.pay.service;

import com.ssy.lingxi.pay.api.dto.request.aliPay.*;
import com.ssy.lingxi.pay.model.assetAccount.AliPayResult;
import com.ssy.lingxi.pay.model.assetAccount.PayResult;

import javax.servlet.http.HttpServletRequest;

/**
 * 支付宝支付接口定义
 * @author lqa
 * @version 2.0.0
 * @date 2021/11/2
 */
public interface IAliPayService {
    /**
     * 统一收单下单并支付页面接口
     */
    AliPayResult pay(AliPayComputerRequest aliPayComputerRequest, HttpServletRequest request);

    /**
     * 支付宝App支付
     */
    AliPayResult appPay(AliPayComputerRequest aliPayComputerRequest, HttpServletRequest request);

    /**
     * 支付宝手机网站支付
     * @param aliPayComputerRequest 接口参数
     * @param request request请求体
     * @return 操作结果
     */
    AliPayResult jsApiPay(AliPayComputerRequest aliPayComputerRequest, HttpServletRequest request);
    /**
     * 查询订单
     */
    AliPayResult orderQuery(AliPayOrderQueryRequest aliPayOrderQueryRequest);

    /**
     * 关闭订单
     * @param aliPayCloseOrderRequest 接口参数
     * @return 操作结果
     */
    AliPayResult closeOrder(AliPayCloseOrderRequest aliPayCloseOrderRequest);
    /**
     * 申请退款
     */
    AliPayResult refund(AliPayRefundRequest aliPayRefundRequest);

    /**
     * 退款查询
     * @param aliPayRefundQueryRequest 接口参数
     * @return  操作结果
     */
    AliPayResult refundQuery(AliPayRefundQueryRequest aliPayRefundQueryRequest);


}
